/* 
 * File:   FinderItem.cpp
 * Author: vicror
 * 
 * Created on November 23, 2011, 12:00 AM
 */

#include "FinderItem.h"
#include "Item.h"
namespace SearchEnginer {
    FinderItem::FinderItem():Basic_Knot() {
        setLetter('\n');
        setIndex(-1);

    }

    FinderItem::FinderItem(const FinderItem& orig)
    : Basic_Knot(orig){
        setLetter(orig.letter());
        setIndex(orig.index());
    }

    FinderItem::~FinderItem() {
    }

    bool FinderItem::operator==(const FinderItem& orig) const {
        return ch == orig.ch;
    }

    bool FinderItem::operator!=(const FinderItem& orig) const {
        return ch != orig.ch;
    }

    bool FinderItem::operator>=(const FinderItem& orig) const {
        return ch >= orig.ch;
    }
    
    bool FinderItem::operator<=(const FinderItem& orig) const {
        return ch <= orig.ch;
    }
    
    bool FinderItem::operator>(const FinderItem& orig) const {
        return ch > orig.ch;
    }

    bool FinderItem::operator<(const FinderItem& orig) const {
        return ch < orig.ch;
    }

    bool FinderItem::operator==(const char& orig) const {
        return ch == orig;
    }

    bool FinderItem::operator!=(const char& orig) const {
        return ch != orig;
    }

    bool FinderItem::operator>=(const char& orig) const {
        return ch >= orig;
    }

    bool FinderItem::operator<=(const char& orig) const {
        return ch <= orig;
    }

    bool FinderItem::operator>(const char& orig) const {
        return ch > orig;
    }

    bool FinderItem::operator<(const char& orig) const {
        return ch < orig;
    }
    Index FinderItem::index() const {
        return _index;
    }

    void FinderItem::setIndex(const Index orig) {
        _index = orig;
    }

    char FinderItem::letter() const {
        return ch;
    }

    void FinderItem::setLetter(const char orig) {
        ch = orig;
    }


}
